package com.atguigu.gulimall.product.service;

import com.baomidou.mybatisplus.extension.service.IService;
import com.atguigu.common.utils.PageUtils;
import com.atguigu.gulimall.product.entity.CategoryEntity;

import java.util.List;
import java.util.Map;

/**
 * 商品三级分类
 *
 * @author wzp
 * @email wangzepengmr@sina.com
 * @date 2020-10-19 20:05:34
 */
public interface CategoryService extends IService<CategoryEntity> {

    PageUtils queryPage(Map<String, Object> params);

    /**
     * 以树形结构返回所有分类
     * @return
     */
    List<CategoryEntity> listWithTree();

    /**
     * 根据分类id集合删除
     * @param asList
     */
    void removeCategoryByIds(List<Long> asList);

    /**
     * 取得分类路径
     * @param catelogId
     * @return
     */
    Long[] findCatelogPath(Long catelogId);

    /**
     * 更新分类详细
     * @param category
     */
    void updateDetail(CategoryEntity category);
}

